package com.pro.mapper;

import com.pro.pojo.JsLoginRecord;
import com.pro.pojo.JsMenu;
import com.pro.pojo.JsMonthCount;
import com.pro.pojo.JsUser;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * ClassName:JsUserMapper
 * Package:com.pro.mapper
 * Description: 登录mapper层
 *
 * @Date:2021/11/3 上午 11:35
 * @Author:太宰
 */

public interface JsUserMapper {
    /* 登录 */
    JsUser getJsUser(@Param("account")String account,@Param("password")String password);
    /* 添加登录日志 */
    Boolean addJsLoginRecord(JsLoginRecord jsLoginRecord);
    /* 修改 */
    Boolean updateUser(@Param("userId")Integer userId,@Param("acatarUrl")String acatarUrl,@Param("password")String password);
    /*获取登录信息*/
    List<JsUser> getLoginMsg(String account);
    /**
     *
     * @author ZPT
     * @date 2021/11/10 14:28
     * @content :根据名字查询
     */
    JsUser loginByName(String username);

    //判断是否解封
    public List<Integer> selectUserEndDate(Integer userId,String endDate);
    /**
     *
     * @author ZPT
     * @date 2021/12/1 19:28
     * @content :总数
     */
    int count();
    /**
     *
     * @author ZPT
     * @date 2021/12/2 20:33
     * @content :查询每个月对应有多少个用户
     */
    List<JsMonthCount> countMonth();


}
